import { configureStore } from '@reduxjs/toolkit';
import menuReducer from './modules/menu';
import tabsReducer from './modules/tabs';
import userReducer from './modules/user';

export const store = configureStore({
  reducer: {
    menu: menuReducer,
    tabs: tabsReducer,
    user: userReducer,
  },
  middleware: (getDefaultMiddleware) =>
    getDefaultMiddleware({
      serializableCheck: false,
    }),
});

export type RootState = ReturnType<typeof store.getState>;
export type AppDispatch = typeof store.dispatch;
